﻿<!DOCTYPE html>

<html class="x-admin-sm">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width" />
    <title>GoodsList</title>
    <link rel="stylesheet" href="~/css/font.css">
    <link rel="stylesheet" href="~/css/xadmin.css">
    @*<script src="~/jquery/dist/jquery.min.js"></script>*@
    <script src="~/lib/layui/layui.js" charset="utf-8"></script>
    <script type="text/javascript" src="~/js/xadmin.js"></script>
</head>
<body>
    <!-- 让IE8/9支持媒体查询，从而兼容栅格 -->
    <!--[if lt IE 9]>
      <script src="https://cdn.staticfile.org/html5shiv/r29/html5.min.js"></script>
      <script src="https://cdn.staticfile.org/respond.js/1.4.2/respond.min.js"></script>
    <![endif]-->
    <div class="x-nav">
        <span class="layui-breadcrumb">
            <a href="">首页111</a>
            <a href="">欢迎页</a>
        </span>
        <a class="layui-btn layui-btn-small" style="line-height:1.6em;margin-top:3px;float:right" onclick="location.reload()" title="刷新">
            <i class="layui-icon layui-icon-refresh" style="line-height:30px"></i>
        </a>
    </div>

    <div class="layui-fluid">
        <div class="layui-col-md12">
            <div class="layui-card">
                <div class="layui-card-header">数据统计</div>
                <div class="layui-card-body ">
                    <ul class="layui-row layui-col-space10 layui-this x-admin-carousel x-admin-backlog">
                        <li class="layui-col-md2 layui-col-xs6">
                            <a href="javascript:;" class="x-admin-backlog-body">
                                <h3>维修站点数</h3>
                                <p>
                                    <cite id="areacount">0</cite>
                                </p>
                            </a>
                        </li>
                        <li class="layui-col-md2 layui-col-xs6">
                            <a href="javascript:;" class="x-admin-backlog-body">
                                <h3>会员数量</h3>
                                <p>
                                    <cite id="usercount">0</cite>
                                </p>
                            </a>
                        </li>
                        <li class="layui-col-md2 layui-col-xs6">
                            <a href="javascript:;" class="x-admin-backlog-body">
                                <h3>产品数量</h3>
                                <p>
                                    <cite id="goodscount">0</cite>
                                </p>
                            </a>
                        </li>
                        <li class="layui-col-md2 layui-col-xs6">
                            <a href="javascript:;" class="x-admin-backlog-body">
                                <h3>快递公司数量</h3>
                                <p>
                                    <cite id="expresscount">0</cite>
                                </p>
                            </a>
                        </li>
                        <li class="layui-col-md2 layui-col-xs6">
                            <a href="javascript:;" class="x-admin-backlog-body">
                                <h3>进货单数量</h3>
                                <p>
                                    <cite id="purchasecount">0</cite>
                                </p>
                            </a>
                        </li>
                        <li class="layui-col-md2 layui-col-xs6 ">
                            <a href="javascript:;" class="x-admin-backlog-body">
                                <h3>维修单数量</h3>
                                <p>
                                    <cite id="repaircount">0</cite>
                                </p>
                            </a>
                        </li>
                    </ul>
                </div>
            </div>
        </div>
    </div>


    <div class="layui-fluid">
        @* 布局类 使用此类不会固定宽度，而是 100%自适应*@
        <div class="layui-row layui-col-space15">
            @* 设置行  列之间间隔 15px*@
            <div class="layui-col-md12">
                @* 设置列  12等分*@
                <div class="layui-card">
                    <div class="layui-card-header">维修统计</div>
                    <div class="layui-card-body ">
                        @*卡片式面板面板通常用于非白色背景色的主体内*@
                        <table class="layui-table" id="goodstablelist" lay-filter="goodstablelist"></table>
                    </div>
                </div>
            </div>
        </div>
    </div>




    <script type="text/javascript">
        //表格数据初始化参数
        layui.use(['table'], function () {
            var $ = layui.$;
            var layer = layui.layer;
            var table = layui.table;

            var options = {
                elem: '#goodstablelist'
                , method: 'post'
               
                , height: 'full-330'
                , url: '/Welcome/WelcomeList'
                , page: {
                    layout: ['limit', 'count', 'prev', 'page', 'next', 'skip']
                }
                , limit: 20
                , limits: [20, 40, 60, 80, 100]
                , cols: [[
                    { field: 'id', title: '编号', width: 80 }
                    , { field: 'userName', title: '维修助理' }
                    , { field: 'areaName', title: '所属门店' }
                    , { field: 'startTime', title: '开始日期' }
                    , { field: 'endTime', title: '结束日期' }
                    , { field: 'count', title: '维修数量' }
                    //, { field: 'cost', title: '维修费用'}
                ]]
            };
            var goodsTable = table.render(options);

            //$.ajax({
            //    type: 'POST',
            //    url: '/Area/ReturnAllArea',
            //    datatype: 'json',
            //    success: function (data) {
            //        if (data.type == 200) {
            //            $('#areacount').text(data.data.length);
            //        }

            //    }
            //});
            //$.ajax({
            //    type: 'POST',
            //    url: '/User/GetAllUserLogin',
            //    datatype: 'json',
            //    success: function (data) {
            //        if (data.type == 200) {
            //            $('#usercount').text(data.data.length);
            //        }
            //    }
            //});
            //$.ajax({
            //    type: 'POST',
            //    url: '/Cargo/GetAllCargo',
            //    datatype: 'json',
            //    data: { gt: 1000 },
            //    success: function (data) {
            //        if (data.type == 200) {
            //            $('#goodscount').text(data.data.length);
            //        }
            //    }
            //});
            //$.ajax({
            //    type: 'POST',
            //    url: '/Express/GetAllExpress',
            //    datatype: 'json',
            //    success: function (data) {
            //        if (data.type == 200) {
            //            $('#expresscount').text(data.data.length);
            //        }
            //    }
            //});
            //$.ajax({
            //    type: 'POST',
            //    url: '/ImportOrder/GetAllImportOrder',
            //    datatype: 'json',
            //    success: function (data) {
            //        if (data.type == 200) {
            //            $('#purchasecount').text(data.data.length);
            //        }
            //    }
            //});
            //$.ajax({
            //    type: 'POST',
            //    url: '/RepairOrder/GetAllRepairList',
            //    datatype: 'json',
            //    success: function (data) {
            //        if (data.type == 200) {
            //            $('#repaircount').text(data.data.length);
            //        }
            //    }
            //});
        });
    </script>
</body>
</html>
